package com.gxar.quick.ar.server.db.mapper;

import com.gxar.quick.ar.server.base.model.exchange.dto.ExchangeItemTransferTypeFrequencyStatDTO;
import com.gxar.quick.ar.server.base.model.exchange.vo.response.AdminExchangeItemTransferTopPageResponse;
import com.gxar.quick.ar.server.db.model.ExchangeItemTransferRecordEntity;

import java.math.BigDecimal;
import java.util.List;

/**
 * @author linsy
 * @version 1.0
 * @created 2024/2/18 10:31
 */
public interface ExchangeItemTransferRecordMapper {

    /**
     * 分页查询
     *
     * @param type 类型
     * @return 响应
     */
    List<ExchangeItemTransferRecordEntity> queryByPage(Integer type);

    /**
     * 收款总额
     *
     * @return 响应
     */
    BigDecimal totalAmountCollected(Integer type);

    /**
     * 已转赠/赠送兑换品总数
     *
     * @return 总数
     */
    Integer totalExchangeItemNum();

    /**
     * 根据类型转赠赠送次数统计
     *
     * @return 不同类型次数
     */
    List<ExchangeItemTransferTypeFrequencyStatDTO> typeTransferFrequencyStat();

    /**
     * 排行榜列表
     * @param type 类型
     * @return 排行榜列表
     */
    List<AdminExchangeItemTransferTopPageResponse> topList(Integer type);

}
